// 这是通过appTool自动生成的rpcx代码，请勿修改
package exampleRpcSev

import (
	"context"

	"gitee.com/kinwyb/appTools/appTool/code-generate/example/server/service"
	rpcxServer "github.com/smallnest/rpcx/server"
)

type RpcxServiceGroup struct {
	arithSev *service.Arith
}

func (r *RpcxServiceGroup) SetArith(arithSev *service.Arith) {
	r.arithSev = arithSev
}
func (r *RpcxServiceGroup) Services(rpcxSev *rpcxServer.Server, meta string) {
	var err error
	if r.arithSev == nil {
		panic("RpcxServiceGroup[Arith]尚未初始化")
	}
	arithsev := &arithRpcxService{Serv: r.arithSev}
	err = rpcxSev.RegisterName("example.arithSev", arithsev, meta)
	if err != nil {
		panic("rpcx服务[arithSev]注册错误:" + err.Error())
	}
	err = rpcxSev.RegisterFunctionName("example.globalFun", "ArithMulFun", ArithMulFun, meta)
	if err != nil {
		panic("rpcx函数[ArithMulFun]注册错误:" + err.Error())
	}
	err = rpcxSev.RegisterFunctionName("example.globalFun", "NoResult", NoResult, meta)
	if err != nil {
		panic("rpcx函数[NoResult]注册错误:" + err.Error())
	}
	err = rpcxSev.RegisterFunctionName("example.globalFun", "GoFunc", GoFunc, meta)
	if err != nil {
		panic("rpcx函数[GoFunc]注册错误:" + err.Error())
	}
	err = rpcxSev.RegisterFunctionName("example.globalFun", "PageTest", PageTest, meta)
	if err != nil {
		panic("rpcx函数[PageTest]注册错误:" + err.Error())
	}
	err = rpcxSev.RegisterFunctionName("example.globalFun", "RpcServerHealth", RpcServerHealth, meta)
	if err != nil {
		panic("rpcx函数[RpcServerHealth]注册错误:" + err.Error())
	}
}
func RpcServerHealth(reqCtx context.Context, arg string, resp *string) error {
	*resp = "example"
	return nil
}
